<!DOCTYPE html>
<html>
<head>
    <title>攻略系列</title>
    <meta charset="utf-8"/>
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
    <link rel="stylesheet" href="/js/plugins/bootstrap-4.1.1-dist/css/bootstrap.min.css">
    <script src="/js/plugins/jquery/jquery.min.js"></script>
    <script src="/js/plugins/bootstrap-4.1.1-dist/js/bootstrap.min.js"></script>
    <link rel="stylesheet" href="/css/font/css/font-awesome.min.css"/>
    <link rel="stylesheet" href="/css/reset.css"/>
    <link rel="stylesheet" href="/css/strategyCatalogs.css"/>
    <script src="/js/plugins/jrender/jrender.min.js"></script>
    <link rel="stylesheet" href="/js/plugins/dialog2/css/dialog.css"/>
    <script src="/js/plugins/dialog2/js/dialog.min.js"></script>
    <script src="/js/common.js"></script>

    <script>
        $(function () {
            var user = JSON.parse(sessionStorage.getItem("user"));
            $.get("/commodities/"+user.id+"/getForms",function (data) {
                console.log(data);
                $("#pills-catalog").renderValues(data);
            });
            $("#pills-comment-tab").click(function () {
                $.get("/hotelForms/"+user.id+"/getHotelForm",function (data) {
                    console.log(data);
                    $("#pills-comment").renderValues(data, {
                        getHref: function (item, value) {
                            var href = $(item).data('href');
                            $(item).attr('href', href + value);
                        }
                    });
                });
            });
        });
    </script>

</head>

<body>
<div class="search-head">
    <div class="row nav-search">
        <div class="col-2">
            <a href="profiles.html">
                <span><i class="fa fa-chevron-left fa-2x"></i></span>
            </a>
        </div>
        <div class="col-10">
            <div class="input-group-sm search">
            </div>
        </div>
    </div>
</div>


<ul class="nav nav-pills nav-justified border border-left-0 border-top-0 border-right-0" id="pills-tab">
    <li class="nav-item ">
        <a class="nav-link active" id="pills-catalog-tab" data-toggle="pill" href="#pills-catalog">
            <span>商城订单</span>
        </a>
    </li>
    <li class="nav-item">
        <a class="nav-link " id="pills-comment-tab" data-toggle="pill" href="#pills-comment">
            <span>酒店订单</span>
        </a>
    </li>
</ul>
<div class="tab-content " id="pills-tabContent">
    <div class="tab-pane fade show active" id="pills-catalog">
        <div render-loop="result">
        <div style="height: 102px;border-top: 1px solid;border-bottom:1px solid; ">
            <div style="width: 130px;height: 100px;float: left">
                <img render-src="result.coverUrl" style="width: 130px;height: 100px;">
            </div>
            <div style="height: 102px;width: 40px;float: left">
            </div>
            <div style="width: 205px;height: 102px;float: left">
                <br>
                <span render-html="result.name"></span><br>
                <span render-html="result.integral"></span>积分
            </div>
        </div>
        </div>
    </div>
    <div class="tab-pane fade " id="pills-comment">
        <div render-loop="result">
            <div style="height: 122px;border-top: 1px solid;border-bottom:1px solid; ">
                <div style="width: 130px;height: 100px;float: left">
                    <a data-href="/hotelContent.html?id=" render-key="result.hotel.id" render-fun="getHref">
                        <img render-src="result.hotel.coverUrl" style="width: 140px;height: 122px;">
                    </a>
                </div>
                <div style="height: 122px;width: 30px;float: left">
                </div>
                <div style="width: 205px;height: 122px;float: left">
                    <span render-html="result.hotel.name"></span><br>
                    入住时间：<span render-html="result.beginDate"></span><br>
                    退房时间：<span render-html="result.endDate"></span><br>
                    房间数：<span render-html="result.roomNumber"></span><br>
                    总金额：<span render-html="result.totalPrice"></span>
                </div>
            </div>
        </div>
    </div>
</div>




</body>
</html>